﻿
<title>角色管理 - 管理员管理 - H-ui.admin v3.0</title>

<section class="Hui-article-box">
	<nav class="breadcrumb"><i class="Hui-iconfont">&#xe67f;</i> 首页 <span class="c-gray en">&gt;</span> 管理员管理 <span class="c-gray en">&gt;</span> 角色管理 <a class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px" href="javascript:location.replace(location.href);" title="刷新" ><i class="Hui-iconfont">&#xe68f;</i></a></nav>
	<div class="Hui-article">
		<article class="cl pd-20">
			<div class="cl pd-5 bg-1 bk-gray">
				<span class="l">
					<a href="javascript:;" data-url="{:url('delete')}" id="patch_delete" class="btn btn-danger radius"><i class="Hui-iconfont">&#xe6e2;</i> 批量删除</a>
					<a href="javascript:;" data-url="{:url('create')}" data-type="full" id="add" class="btn btn-primary radius" ><i class="Hui-iconfont">&#xe600;</i> 添加角色</a>
				</span>
				<span class="r">共有数据：<strong>{:count($list)}</strong> 条</span>
			</div>
			<div class="mt-10">
			<table class="table table-border table-bordered table-hover table-bg">
				<thead>
					<tr>
						<th scope="col" colspan="6">角色管理</th>
					</tr>
					<tr class="text-c">
						<th width="25"><input type="checkbox" value="" name=""></th>
						<th width="40">ID</th>
						<th width="200">角色名</th>
						<th>用户列表</th>
						<th width="300">描述</th>
						<th width="70">操作</th>
					</tr>
				</thead>
				<tbody>
					{foreach $list as $v}
					<tr class="text-c" data-id="{$v.id}">
						<td>
							{if ($v.id != 1)}
							<input type="checkbox" class="row_check" value="{$v.id}" name="">
							{/if}
						</td>
						<td>{$v.id}</td>
						<td>{$v.role_name}</td>
						<td>{:implode(',',array_column($v.users, 'username'))}</td>
						<td>{$v.desc}</td>
						<td class="f-14">
							{if ($v.id != 1)}
							<a title="编辑" class="ml-5 edit" data-url="{:url('edit', ['id'=>$v.id])}" data-type="full" href="javascript:;" style="text-decoration:none"><i class="Hui-iconfont">&#xe6df;</i></a>
							<a title="删除" class="ml-5 delete" data-url="{:url('delete', ['id'=>$v.id])}" href="javascript:;" style="text-decoration:none"><i class="Hui-iconfont">&#xe6e2;</i></a>
							{/if}
						</td>
					</tr>
					{/foreach}
				</tbody>
			</table>
			</div>
		</article>
	</div>
</section>

<!--请在下方写此页面业务相关的脚本-->
<script type="text/javascript" src="/static/admin/lib/My97DatePicker/4.8/WdatePicker.js"></script>
<script type="text/javascript" src="/static/admin/lib/datatables/1.10.0/jquery.dataTables.min.js"></script>
<script type="text/javascript" src="/static/admin/lib/laypage/1.2/laypage.js"></script>
<script type="text/javascript" src="/static/admin/logic/curd.js"></script>
<script type="text/javascript">

</script>
<!--/请在上方写此页面业务相关的脚本-->
